package com.efesco.oa.announce;

import com.bstek.dorado.data.*;
import com.bstek.dorado.data.db.SqlDataset;
import com.bstek.dorado.common.*;
import com.efesco.common.CommUtil;

/**
 * announce_dataset_announce_more_listListener
 */
public class announce_dataset_announce_more_listListener extends AbstractDatasetListener {
  public boolean beforeLoadData(Dataset dataset)
     throws Exception {

	  SqlDataset ds = (SqlDataset) dataset;
	  String sql="select ia.INFO_ANNOUNCE_ID,ia.ANNOUNCE_TITLE,ia.MSG_CLASS,ia.SEND_DATE,ia.OVERDUE_DATE " +
	  		"from s_info_announce ia ,s_info_accept_man iam " +
	  		"where ia.is_delete is null and ia.info_announce_id=iam.info_announce_id " +
	  		"and iam.read_man_id='"+CommUtil.getForEmpId()+"'";
	  sql += CommUtil.setConditionSQL(ds);
	  ds.setSql(sql);

    return true;
  }

}
